package com.tecklab.demo.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.Date;


/**
 * @Deacription TODO
 * @Author sunking
 * @Date 2022/12/7} 下午4:18
 **/
@Data
@AllArgsConstructor
@NoArgsConstructor
@TableName("user")
public class UserEntity {

    @TableId(type = IdType.AUTO)
    private Integer id;

    private String username;

    private String password;

    /**
     * 1: 管理员，2: 普通用户 
     */
    private int accountType;

    private String email;

    private String phone;

    /**
     * 0: 禁用 1: 正常
     */
    private int status;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date updateTime;
}
